import pygame
image=pygame.image.load("pole.jpg")
image.set_colorkey((137,44,75))
import Platform

class Pole(Platform.Platform):
	def __init__(self,pos=(0,0),im=image):
		Platform.Platform.__init__(self,pos,im)
	def drawingInformation(self):
		return (self.pos[0]-0.5*self.getWidth(),self.pos[1]+0.5*self.getHeight()),self.image
	def xLanding(self,objecto):
		pass
	def yLanding(self,objecto):
		if self.rightCondition(objecto) or self.leftCondition(objecto) or self.upperCondition(objecto) or self.lowerCondition(objecto):
			objecto.reposition(self.pos[0],self.pos[1]+0.5*self.getHeight())
			objecto.y_bound=self
			self.boundedList.append(objecto)
	def hasFallenOff_y(self,objecto):
		objecto.x=self.pos[0]
	def upperSide(self):
		return self.pos[1]+0.5*self.getHeight()
	def lowerSide(self):
		return self.pos[1]-0.5*self.getHeight()
	def leftSide(self):
		return self.pos[0]-0.5*self.getWidth()
	def rightSide(self):
		return self.pos[0]+0.5*self.getWidth()
